import * as types from './actionTypes';
import Immutable from 'seamless-immutable';
const initialState = Immutable({
    rows:{
        dataSource:[],
        columns:[]
    },
    row:{}
});

export default function app(state = initialState, action = {}) {
    switch (action.type) {
        case types.SET_ROWS:
            return state.set("rows",action.rows);
        case types.SET_ROW:
            return state.set("row", action.row);
        default:
            return state;
    }
}
